use super::hitls_type::{HITLS_Config, HITLS_Ctx};
pub const INDICATE_VALUE_SUCCESS: u32 = 1;
pub const INDICATE_EVENT_LOOP: u32 = 1;
pub const INDICATE_EVENT_EXIT: u32 = 2;
pub const INDICATE_EVENT_READ: u32 = 4;
pub const INDICATE_EVENT_WRITE: u32 = 8;
pub const INDICATE_EVENT_HANDSHAKE_START: u32 = 16;
pub const INDICATE_EVENT_HANDSHAKE_DONE: u32 = 32;
pub const INDICATE_EVENT_STATE_CONNECT: u32 = 4096;
pub const INDICATE_EVENT_STATE_ACCEPT: u32 = 8192;
pub const INDICATE_EVENT_ALERT: u32 = 16384;
pub const INDICATE_EVENT_READ_ALERT: u32 = 16388;
pub const INDICATE_EVENT_WRITE_ALERT: u32 = 16392;
pub const INDICATE_EVENT_STATE_ACCEPT_LOOP: u32 = 8193;
pub const INDICATE_EVENT_STATE_ACCEPT_EXIT: u32 = 8194;
pub const INDICATE_EVENT_STATE_CONNECT_LOOP: u32 = 4097;
pub const INDICATE_EVENT_STATE_CONNECT_EXIT: u32 = 4098;
pub type HITLS_InfoCb =
    ::std::option::Option<unsafe extern "C" fn(ctx: *const HITLS_Ctx, eventType: i32, value: i32)>;
unsafe extern "C" {
    pub fn HITLS_SetInfoCb(ctx: *mut HITLS_Ctx, callback: HITLS_InfoCb) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_GetInfoCb(ctx: *const HITLS_Ctx) -> HITLS_InfoCb;
}
unsafe extern "C" {
    pub fn HITLS_CFG_SetInfoCb(config: *mut HITLS_Config, callback: HITLS_InfoCb) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_CFG_GetInfoCb(config: *const HITLS_Config) -> HITLS_InfoCb;
}
pub type HITLS_MsgCb = ::std::option::Option<
    unsafe extern "C" fn(
        writePoint: i32,
        tlsVersion: i32,
        contentType: i32,
        msg: *const ::std::os::raw::c_void,
        msgLen: u32,
        ctx: *mut HITLS_Ctx,
        arg: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn HITLS_SetMsgCb(ctx: *mut HITLS_Ctx, callback: HITLS_MsgCb) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_CFG_SetMsgCb(config: *mut HITLS_Config, callback: HITLS_MsgCb) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_CFG_SetMsgCbArg(
        config: *mut HITLS_Config,
        arg: *mut ::std::os::raw::c_void,
    ) -> i32;
}
